//
//  CCNode.h
//  ShadowMapping
//
//  Created by Daniel Corleone on 18/6/14.
//  Copyright (c) 2014年 iCloverStudio. All rights reserved.
//

#ifndef __ShadowMapping__CCNode__
#define __ShadowMapping__CCNode__

#include "CCDataType.h"
#include "PlatformFeatures.h"

BECO_NAMESPACE_BEGIN

class Node {
public:
	enum NodeType {
		eCamera = 0,
		eLight,
		eMesh,
		eSceneManager,
		eEmptyNode,
	};

public:
	explicit Node() : nodeType(eEmptyNode), parent(0), name(""), identity(-1) {}
	explicit Node(NodeType _nodeType, const String& nodeName) : nodeType(_nodeType), parent(0), name(nodeName), identity(0) {}
	explicit Node(NodeType _nodeType, Node* superNode, const String& nodeName) : nodeType(_nodeType), parent(0), name(nodeName), identity(0) {}
    virtual ~Node() {}
   
public:
    virtual void Update(const Real timeInterval) {}
    virtual void Render(const Real timeInterval) {}

public:
	NodeType GetNodeType(void) const { return nodeType; }
    
protected:
	NodeType nodeType;
    Int32 identity;
    String name;
    Node* parent;
};

BECO_NAMESPACE_END

#endif /* defined(__ShadowMapping__CCNode__) */
